<%@page import="com.oms.domain.Message" %>
<%@ page import="com.oms.domain.User" %>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>发送信息详情</title>
	<script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery/jquery-3.0.0.min.js"></script>
	<script type="text/javascript">
		$(function(){
			$(".delete").click(function(){
				var href = $(this).attr("href");
				$("form").attr("action", href).submit();			
				return false;
			});
		});
	</script>
</head>
<body>
	
	<form id="form" action="" method="POST">
		<input type="hidden" name="_method" value="DELETE"/>
	</form>

	<h1>${message.messageTitle }</h1>
	<table align="center">
		<tr>
			<td>标题:</td>
			<td>${message.messageTitle}</td>
		</tr>
		<tr>
			<td>发件人:</td>
			<td>${message.user.name}</td>
		</tr>
		<tr>
			<td>时间:</td>
			<td>${message.sendTime}</td>
		</tr>
		<tr>
			<td>收件人:</td>
			<td>${message.user.name}</td>
		</tr>
		<tr>
			<td>消息类型:</td>
			<td>${message.messageType}</td>
		</tr>
		<tr>
			<td>内容:</td>
			<td><p>${message.messageComment}</p></td>
		</tr>
		<tr>
			<td><a class="delete" href="${pageContext.request.contextPath}/message/send/${message.messageId}.do">删除</a></td>
		</tr>
	</table>
</body>
</html>